package cn.tedu.boyou.acticle.service.impl;

import cn.tedu.boyou.acticle.domain.SaleTag;
import cn.tedu.boyou.acticle.mapper.SaleTagMapper;
import cn.tedu.boyou.acticle.service.ISaleTagService;
import com.alibaba.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@Service
public class SaleTagServiceImpl implements ISaleTagService{

    @Autowired
    private SaleTagMapper saleTagMapper;

    @Override
    public void insert(SaleTag sale) {
        saleTagMapper.insert(sale);
    }

    @Override
    public List<SaleTag> listAll() {
        return saleTagMapper.selectAll();
    }

    @Override
    public List<SaleTag> getTagsBySaleId(Long saleId) {
        return saleTagMapper.selectBySaleId(saleId);
    }
}
